﻿@using HrEFCore
@model MC
<!DOCTYPE html>
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<script src="~/aa/vue/dist/vue.js"></script>
	<script src="~/aa/element-ui/lib/index.js"></script>
	<link href="~/aa/element-ui/lib/theme-chalk/index.css" rel="stylesheet" />
	<script src="~/aa/axios/dist/axios.js"></script>
	<link rel="stylesheet" href="~/css/table.css" type="text/css"></link>
	<script type="text/javascript" src="~/javascript/comm/comm.js"></script>
	<script type="text/javascript" src="~/javascript/jquery-1.7.2.js"></script>
	<style type="text/css">
		body {
			background: rgb(253,244,227);
		}

		.TD_STYLE1 {
			background: #E6DDCE;
			/* color:white; */
		}

		.TD_STYLE2 {
			background: rgb(253,244,227);
		}

		.INPUT_STYLE2 {
			background: rgb(253,244,227);
		}
	</style>
</head>
<body>
	<form method="post" action="/MC/SelectByName" id="mcSelect">
		<table width="100%">
			<tr>
				<td>
					<font color="black">您正在做的业务是：人力资源--调动管理--调动查询 </font>
				</td>
			</tr>
			<tr>
				<td align="right">
					<input type="submit" value="查询" class="BUTTON_STYLE1" />
					<input type="hidden" name="result" value="toQueryList" />
				</td>
			</tr>
		</table>
		<table width="100%" border="1" cellpadding=0 cellspacing=1
			   bordercolorlight=#848284 bordercolordark=#eeeeee
			   class="TABLE_STYLE1 table-bordered">
			<tr class="TR_STYLE1">
				<td width="16%" class="TD_STYLE1">
					请选择员工所在机构
				</td>
				<td width="84%" class="TD_STYLE2">
					<el-cascader :options="options" v-model="value" v-on:change="handleChange"></el-cascader>
					<input type="text" style="display:none" v-model="firstid" name="NewFirstKindId" />
					<input type="text" style="display:none" v-model="secondid" name="NewSecondKindId" />
					<input type="text" style="display:none" v-model="thirdid" name="NewThirdKindId" />
				</td>
			</tr>
			<tr>
				<td class="TD_STYLE1">
					请选择职位
				</td>
				<td width="84%" class="TD_STYLE2">
					<el-cascader :options="options2" v-model="value2" v-on:change="handleChange2"></el-cascader>
					<input type="text" style="display:none" v-model="majorkindid" name="NewMajorKindId" />
					<input type="text" style="display:none" v-model="majorid" name="NewMajorId" />
				</td>
			</tr>
			<tr>
				<td class="TD_STYLE1">
					请输入建档时间
				</td>
				<td width="84%" class="TD_STYLE2">
					<el-date-picker v-model="value6"
									type="date" name="startDate"
									placeholder="选择日期">
					</el-date-picker>
					至
					<el-date-picker v-model="value7"
									type="date" name="endDate"
									placeholder="选择日期">
					</el-date-picker>
				</td>
			</tr>
		</table>
	</form>
	<script>
		new Vue({
			el: '#mcSelect',
			data: {
				value: "",
				value2:"",
				options: [],
				options2:[],
				firstid: "",
				secondid: "",
				thirdid: "",
				value6:'',
				value7:'',
				majorkindid:'',
				majorid:''
			},
			methods: {
				fill() {
					axios.get('/HF/GetFirstKinds').then(res => {
						this.options = res.data.map(item => {
							return {
								value: item.value,
								label: item.label,
								children: item.children
							};
						});
					}).catch(err => {
						console.log(err);
					});
					axios.get('/MC/GetMajorKindName').then(res => {
						this.options2 = res.data.map(item => {
							return {
								value: item.value,
								label: item.label,
								children: item.children
							};
						});
					}).catch(err => {
						console.log(err);
					});
				},
				handleChange(value) {
					if (value != null) {
						this.firstid = value[0];
						this.secondid = value[1];
						this.thirdid = value[2];
					}
				},
				handleChange2(value) {
					if (value != null) {
						this.majorkindid = value[0];
						this.majorid = value[1];
					}
				}
			},
			mounted: function () {
				this.fill();
			}
		})
	</script>
</body>
</html>